import {assign} from '@/utils/assign.js'
/**
 * @auther zhonghuanting
 * 保存静动态令牌
 */
const state = {
     token:{
		 JWT:'',
		 user:{}
	 }
}

const getters = {
    token: state => state.token
}

const mutations = {
    TOKEN(state, data) {
       state.token = assign(state.token,data)
    }
}
const actions = {
    token({ commit, state }, data) {
        commit('TOKEN', data)
    }
}

export default{
    state,
    getters,
    mutations,
    actions
}